<html>
<head>
<title>添加用户</title>
{% include "systy.html" %}

</head>
<body>
{% ifnotequal username None%}

{% ifequal userpermissions "运维经理" %}
    <div>
    <form action="" method="post">
        <table class="add_table_01">
            <tr>
                <td width="70px" class="hostadd_td_left">帐号：</td>
                <td >{{ fr.user }} </td>
            </tr>
            <tr>
                <td width="70px" class="hostadd_td_left">姓名：</td>
                <td >{{ fr.name }} </td>
            </tr>
            <tr>
                <td width="70px" class="hostadd_td_left">密码：</td>
                <td >{{ fr.passwd }} </td>
            </tr>
            <tr>
                <td width="70px" class="hostadd_td_left">部门：</td>
                <td >
                    <select class="useradd_select" name="select1" id="select1">
                    <option value="-1">选择职位</option>
                    {% for i in departments%}
                        <option value="{{i.name}}">{{i.name}}</option>
                    {% endfor %}
                    </select> 
                
                </td>
            </tr>
            <tr>
                <td width="70px" class="hostadd_td_left">电话：</td>
                <td >{{ fr.phone }} </td>
            </tr>
            <tr>
                <td width="70px" class="hostadd_td_left">职位：</td>
                <td >
                    <select class="useradd_select" name="select2" id="select2">
                    <option value="-1">选择职位</option>
                    {% for i in usergroups%}
                        <option value="{{i.name}}">{{i.name}}</option>
                    {% endfor %}
                    </select>                
                 </td>
            </tr>
            <tr>
                <td width="70px" class="hostadd_td_left">邮箱：</td>
                <td >{{ fr.email }} </td>
            </tr>

            <tr>
                <td width="70px" class="hostadd_td_left">Q Q：</td>
                <td >{{ fr.qq }} </td>
            </tr>        
            <tr>
                <td></td>
                <td><button type="submit" class="btn btn-primary btn-sm hostadd_button"> 提 交 </button></td>
            </tr>
        </table>
</form>


    {% else %}
    你无权添加用户
    {% endifequal %}


{% else %}
你无权访问，请<a href="/login.html">登陆!</a>
{% endifnotequal%}
</div>
</body>
</html>
